package com.gzhryc.net_marketing.cloud.business.dao.enums;

public class TeamPayApplyMemberEnum {

	public static enum State {

		Waiting(1, "等待参与"), Participating(2, "参与中"), Finish(3, "完成")
			, Drain(4, "流拼"), Close(5, "关闭");

		private Integer index;
		private String note;

		State(Integer index, String note) {
			this.index = index;
			this.note = note;
		}

		public Integer index() {
			return index;
		}

		public String note() {
			return note;
		}

		public static String note(Integer index) {
			State[] temp = State.values();
			for (int i = 0; i < temp.length; i++) {
				State item = temp[i];
				if (item.index.equals(index)) {
					return item.note;
				}
			}
			return null;
		}
	}
	
	public static enum PayState {

		Waiting(1, "等待支付"), Success(2, "支付成功"), Fail(3, "支付失败")
			, RefundSuccess(4, "退款成功"), RefundError(5, "退款失败");

		private Integer index;
		private String note;

		PayState(Integer index, String note) {
			this.index = index;
			this.note = note;
		}

		public Integer index() {
			return index;
		}

		public String note() {
			return note;
		}

		public Integer getIndex() {
			return index;
		}

		public String getNote() {
			return note;
		}

		public static String note(Integer index) {
			PayState[] temp = PayState.values();
			for (int i = 0; i < temp.length; i++) {
				PayState item = temp[i];
				if (item.index.equals(index)) {
					return item.note;
				}
			}
			return null;
		}
	}

	public static enum RoleType {

		Commander(1, "团长"), LeagueMember(2, "团员");

		private Integer index;
		private String note;

		RoleType(Integer index, String note) {
			this.index = index;
			this.note = note;
		}

		public Integer index() {
			return index;
		}

		public String note() {
			return note;
		}

		public static String note(Integer index) {
			RoleType[] temp = RoleType.values();
			for (int i = 0; i < temp.length; i++) {
				RoleType item = temp[i];
				if (item.index.equals(index)) {
					return item.note;
				}
			}
			return null;
		}
	}
}
